#ifndef CSTBOY_H_INCLUDED
#define CSTBOY_H_INCLUDED

#include "CZ80.h"
#include "CPPU.h"

////////////////////////////////////////////////////////////////////////////////////////////////////

class CSTBoy {
    public:
        virtual             ~CSTBoy         ();
        static CSTBoy*      GetSingleton    ();
        bool                LoadGame        ( const char[] );
        uint8_t             ReadMemory      ( uint16_t );
        void                WriteMemory     ( uint16_t, uint8_t );
        void                Run             ();

    private:
                            CSTBoy          ();

        static CSTBoy*      mInstance;
        CZ80*               mZ80;
        CPPU*               mPPU;
        uint8_t*            mROM;
        bool                mIME;
        int                 mPendingEI;
        int                 mPendingDI;
};

////////////////////////////////////////////////////////////////////////////////////////////////////

#endif